package com.zgs.mall.product.web;

import com.zgs.mall.product.service.SkuInfoService;
import com.zgs.mall.product.vo.SkuitemVo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

import java.util.concurrent.ExecutionException;

@Controller
public class ItemController {
    @Autowired
    SkuInfoService skuInfoService;
    @GetMapping("/{skuId}.html")
    public String skuItem(@PathVariable(value = "skuId")  Long skuId) throws ExecutionException, InterruptedException {
        SkuitemVo item=skuInfoService.item(skuId);
        return "item";
    }
}
